<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="Developed By M Abdur Rokib Promy">
<meta name="author" content="cosmic">
<meta name="keywords" content="Bootstrap 3, Template, Theme, Responsive, Corporate, Business">
<link rel="shortcut icon" href="${Prefix}images/favicon.png">
<title>
<#if Site.seoTitle?? && Site.seoTitle !="">${Site.seoTitle}<#else>${Site.name}</#if>
</title>

<link href="${Prefix}node_modules/animate.css/animate.min.css" rel="stylesheet" >
<link href="${Prefix}node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<link href="${Prefix}node_modules/font-awesome/css/font-awesome.min.css" rel="stylesheet">
<link href="${Prefix}node_modules/element-ui/lib/theme-chalk/index.css" rel="stylesheet">
<link href="${Prefix}node_modules/swiper/dist/css/swiper.min.css" rel="stylesheet" >

<link href="${Prefix}css/main.css" rel="stylesheet">
<link href="${Prefix}css/header.css" rel="stylesheet">
<link href="${Prefix}css/footer.css" rel="stylesheet">
<link href="${Prefix}css/policy.css" rel="stylesheet">

<script src="${Prefix}node_modules/jquery/dist/jquery.min.js"></script>
<script src="${Prefix}node_modules/wowjs/dist/wow.min.js"></script>
<script src="${Prefix}node_modules/swiper/dist/js/swiper.min.js"></script>
<script src="${Prefix}node_modules/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="${Prefix}node_modules/less/dist/less.js"></script>
<script src="${Prefix}node_modules/vue/dist/vue.js"></script>
<script src="${Prefix}node_modules/element-ui/lib/index.js"></script>


<#assign firstAncestor = Catalog.ancestors?split(':')[0]>

<@cms_catalog id="${firstAncestor}" level="Self">
<#list DataList as c1>
<#assign alias = c1.alias>
<#assign link = c1.link>
</#list>
</@cms_catalog>
<script>
  
$(document).ready(function(){
  const id = $('#current-catalog-alias').text();
  $('#' + id).addClass("policy-active");

  const id2 = $('#main-catalog-alias').text();
  if(id2 == 'policy'){
    $('.options-bar-name').text('政策分类');
  }
  if(id2 == 'publicity'){
    $('.options-bar-name').text('信息分类');
  }
  if(id2 == 'investment'){
    $('.options-bar-name').text('招商引资');
  }

  $(".options-bar-item").click(function(){
    // 如果点击的按钮不是已经激活的，则激活它
    if ($(this).hasClass("policy-active")) {
      const href = "${link}"
      window.location.href = href
    } else {
      // 如果点击的按钮已经激活，则移除激活状态
      const href = $(this).attr("href");
      window.location.href = href
    }
  });
});
</script>
</head>

<body class="policy">
<@cms_include ssi="false"file="quick_nva.template.html"></@cms_include>
<!--header start-->
<@cms_include ssi="false"file="header.template.html"></@cms_include>
<!--header end-->

<div style="display: none;" id="current-catalog-alias">${Catalog.alias}</div>

<#assign firstAncestor = Catalog.ancestors?split(':')[0]>
<@cms_catalog id="${firstAncestor}" level="Self">
<#list DataList as c1>
<div class="policy-top" style="background-image: url('${internalUrl(c1.logo)}');">
  <div class="container wow fadeInLeft">
  	<div class="row">
      <div class="col-lg-12" >
        <div class="policy-top-text">
          <div class="text1">${c1.name}</div>
          <div class="text2">${c1.description}</div>
          <div style="display: none;" id="main-catalog-alias">${c1.alias}</div>
        </div>
      </div>
    </div>
  </div>
</div>
</#list>
</@cms_catalog>

<div class="container wow fadeInLeft policy-center">
  <div class="row">
    <div class="col-lg-3" >
      <div class="options-bar">
        <div class="options-bar-name">-</div>
        <@cms_catalog id="${firstAncestor}" level="Self">
        <#list DataList as c>
          <@cms_catalog alias="${c.alias}" level="child" size="10">
            <#list DataList as c1>
              <a >
                <div class="options-bar-item" id="${c1.alias}" href="${c1.link}" >
                  ${c1.name}
                </div>
              </a>
            </#list>
          </@cms_catalog >
        </#list>
      </@cms_catalog>
      </div>
      <@cms_catalog id="${firstAncestor}" level="Self" size="1">
      <#list DataList as c1>
      <#if c1.alias=='policy' || c1.alias=='investment'>
      <div class="hot-tipcs">
        <div class="hot-tipcs-title">热点专题</div>
        <@cms_catalog id="${firstAncestor}" level="Self" size="1">
          <#list DataList as c1>
            <@cms_content hasattribute="hot" catalogalias="${c1.alias}" level="CurrentAndChild" size="3">

              <#if DataList?size == 0>
              <div class="no-data">
                  <img src="${Prefix}images/empty-data.png" alt=""><span>暂无数据</span>
              </div>
              <#else>
              <#list DataList as content>
              <div class="hot-tipcs-text">
                <a href="${content.link}" target="_blank" rel="noopener noreferrer">
                  ${content.title} 
                </a>
              </div>
              <div class="hot-tipcs-time">${dateFormat(content.publishDate,"yyyy-MM-dd")}</div>
              </#list>
              </#if>

            </@cms_content>  
          </#list>
        </@cms_catalog >
      </div>
      </#if>
      </#list>
      </@cms_catalog >
    </div>
    <div class="col-lg-9" >
      <div class="options-content-list ">
        <div class="options-content-title">
          <div class="options-content-name">${Catalog.name}</div>
        </div>

        <@cms_content catalogalias="${Catalog.alias}" level="CurrentAndChild" size="10" page="true">
        
          <#if DataList?size == 0>
          <div class="no-data">
              <img src="${Prefix}images/empty-data.png" alt=""><span>暂无数据</span>
          </div>
          <#else>
          <#list DataList as content>
          <a href="${content.link}" target="_blank" rel="noopener noreferrer">
            <div class="options-content-item">
              <div class="options-content-text">${content.title}</div>
              <div class="options-content-time">${dateFormat(content.publishDate,"yyyy-MM-dd")}</div>
            </div>
          </a>
          </#list>
          </#if>

        </@cms_content>  
      </div>

      <@cms_include ssi="false"file="paginator.template.html"></@cms_include>
  
    </div>
  </div>
</div>

<@cms_include ssi="false"file="footer.template.html"></@cms_include>
</body>

</html>